<?php
/*
 * Licensed this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

namespace org\boapi\ui\util;

/**
 * Helper type for user interfaces
 * <strong>Attention!</strong> Returning values are written for using with (X)HTML.
 * @author Sebastian Ritter
 * @version 1.0.0.0
 * @license Apache License Version 2.0
 */
class ShoppingUIHelper {

    /**
     * Use &lt;input<&gt; tag with including...
     * <input name="vorname" type="text" size="30" maxlength="30" value="Michaela">
     * @return Returns input pattern for ISSN
     * @see org.boapi.shop.ISSN
     */
    public function getMaskForISSN () {
      return 'type="text" size ="9" maxlength="9" value="####-###A" title="Please replacing # with ISSN."';	
    }
    /**
     * @return Return input pattern for actually ISMN
     * @see org.boapi.shop.ISMN
     */
    public function getMaskForISMN () {
      return 'type="text" size ="17" maxlength="17" value="979-0-#####-###-A" title="Please replacing # with ISMN."';	
    }
    /**
     * @return Return input pattern for actually ISBN
     * @see org.boapi.shop.ISBN13
     */
    public function getMaskForISBN () {
      return 'type="text" size ="17" maxlength="17" value="97#-#-#####-###-A" title="Please replacing # with ISBN."';	
    }
    /**
     * Use &lt;input<&gt; tag with including...
     * @return Return input pattern for old ISBN
     * @see org.boapi.shop.ISBN10
     */
    public function getMaskForISBN10 () {
      return 'type="text" size ="13" maxlength="13" value="#-#####-###-A" title="Please replacing # with ISBN."';	
    }
    /**
     * @return Return input pattern for EAN13
     */
    public function getMaskForEAN () {
      return getMaskForGTIN();	
    }
    /**
     * @return Return input pattern for GTIN
     */
    public function getMaskForGTIN () {
      return 'type="text" size ="17" maxlength="17" value="###-#-#####-###-A" title="Please replacing # with EAN."';	
    }
}
?>
